package com.authine.cloudpivot.ext.service.voucher;

import com.authine.cloudpivot.ext.dto.model.invoice.InvoiceApply;
import com.authine.cloudpivot.ext.dto.model.settle.Settle;

import java.util.List;

/**
 * @Author: liwei
 * @DateTime: 2021/8/16
 * @Description: TODO
 */
public interface KingDeeFinanceService {
    /**
     * 财务 确认收票 场景 生成凭证调用
     * @param invoiceApply
     */
    void receiveInvoiceInvoke(InvoiceApply invoiceApply);

    /**
     * 无效发票,e.g 作废
     * 开票申请单回滚，需要将对应的
     * @param invoiceApplyList
     */
    void doInvalidInvoice(List<InvoiceApply> invoiceApplyList);

    /**
     *  平台采购付款
     * @param settleList 结算数据
     */
    void settlePurchasePayment(List<Settle> settleList);

    /**
     * 删除收付款凭证 （支持单笔作废）
     * @param id 结算单id
     */
    void deleteAdvanceSettle(String id);

    /**
     * 取消付款，删除凭证
     * @param settleDoneList
     */
    void close(List<Settle> settleDoneList);

    /**
     * 创建预收/付款
     * @param settle
     */
    void createAdvanceSettle(Settle settle);

    /**
     * 退款凭证
     * @param settleList
     */
    void refundConfirm(List<Settle> settleList);

    /**
     * 取消退款
     * @param settleList
     */
    void refundCancel(List<Settle> settleList);

    /**
     * 按照发票核销，核销凭证
     * @param settleEntity
     */
    void writeOffSettleByInvoice(Settle settleEntity);

    /**
     * 取消核销凭证
     * @param id 结算单id
     */
    void writeOffCancel(String id);
}
